<?php
    if (!defined('APPPATH')) exit('No direct script access allowed');

    require_once(APPPATH.'libraries/utils/translation/class.translation.php');
    
    if(isset($_GET['lang']))
        $translate = new Translation($_GET['lang'], true);
    else {
        if(!empty($lang))
            $translate = new Translation($lang, true);
        else
            $translate = new Translation('en', true);
    }
?>

<h2><?php $translate->__('Upload new image'); ?></h2>
<form method="POST" action="<?php echo site_url() . "/admin/multimedia_controller/upload"; ?>" name="upload" enctype="multipart/form-data">
    <table cellpadding="0" cellspacing="0" width="100%">
        <thead>
            <tr>
                <th><?php $translate->__('Upload new gallery images'); ?></th>
                <th></th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td><?php $translate->__('Name'); ?></td>
                <td><input type="text" name="name" value="" /></td>
            </tr>
            <!-- restaurant customization -->
            <?php
                if(false) {
            ?>
            <?php
                if(!empty($options)) {
            ?>
                <tr>
                    <td>Menu</td>
                    <td>
                        <select name="menu">
                                <option value="0"></option>
                                <?php
                                    foreach($options as $key => $option) {
                                ?>
                                        <option value=<?php echo $option['menu_id'] ?>><?php echo $option['name'] ?></option>
                                <?php
                                    }
                                ?>
                        </select>
                    </td>
                </tr>
            <?php
                }
            ?>
            <?php
                }
            ?>
            <tr>
                <td><?php $translate->__('BROWSE'); ?></td>
                <td><input type="file" name="userfile" /></td>
            </tr>
            <?php if (!empty($error)) echo $error; ?>
        </tbody>
        <tfoot>
            <tr>
                <td colspan="2">
                    <button><?php $translate->__('Add image'); ?></button>
                </td>
            </tr>
        </tfoot>
    </table>
</form>